//
//  LPPArenaController.m
//  Lottery
//
//  Created by 刘盼 on 16/1/21.
//  Copyright © 2016年 lhheh. All rights reserved.
//

#import "LPPArenaController.h"

@interface LPPArenaController ()

@end

@implementation LPPArenaController

- (void)viewDidLoad {
    [super viewDidLoad];
    //背景图片失真
   // self.view.backgroundColor = [UIColor colorWithPatternImage:[UIImage imageNamed:@"NLArenaBackground"]];
    
    self.view.layer.contents = (__bridge id _Nullable)([UIImage imageNamed:@"NLArenaBackground"].CGImage);
    
    //设置导航栏背景颜色
    [self.navigationController.navigationBar setBackgroundImage:[UIImage imageNamed:@"NLArenaNavBar64"] forBarMetrics:UIBarMetricsDefault];
    //设置选择按钮
    UISegmentedControl *seg = (UISegmentedControl *)self.navigationItem.titleView;
    //设置背景颜色
    [seg setBackgroundImage:[UIImage imageNamed:@"CPArenaSegmentBG"] forState:UIControlStateNormal barMetrics:UIBarMetricsDefault];
    
    [seg setBackgroundImage:[UIImage imageNamed:@"CPArenaSegmentSelectedBG"] forState:UIControlStateSelected barMetrics:UIBarMetricsDefault];
    //设置字体颜色
    [seg setTitleTextAttributes:@{NSForegroundColorAttributeName:[UIColor whiteColor]} forState:UIControlStateNormal];
    
    [seg setTitleTextAttributes:@{NSForegroundColorAttributeName:[UIColor whiteColor]} forState:UIControlStateSelected];
    
    
}


@end
